package {
	import controller.StartupSimpleDemoStartupCommand;	
	
	import org.puremvc.as3.multicore.patterns.facade.Facade;	
	
	/**
	 * @author Darshan Sawardekar
	 */
	public class StartupSimpleDemoFacade extends Facade {
		
		static public const STARTUP:String = "startup";
		
		static public function getInstance(key:String):StartupSimpleDemoFacade {
			if (instanceMap[key] == null) {
				instanceMap[key] = new StartupSimpleDemoFacade(key);
			}
			
			return instanceMap[key] as StartupSimpleDemoFacade;
		}
		
		public function StartupSimpleDemoFacade(key:String) {
			super(key);
		}
		
		override protected function initializeController():void {
			super.initializeController();
			
			registerCommand(STARTUP, StartupSimpleDemoStartupCommand);
		} 
		
		public function startup(app:StartupSimpleDemo):void {
			sendNotification(STARTUP, app);
		}
		
	}
}
